
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
    <meta name="description" content="Responsive Web UI Kit &amp; Dashboard Template based on Bootstrap">
    <meta name="author" content="AdminKit">
    <meta name="keywords" content="adminkit, bootstrap, web ui kit, dashboard template, admin template">

    <link rel="shortcut icon" href="img/icons/icon-48x48.png"/>

    <title>事项审核</title>

    <link href="${pageContext.request.contextPath}/css/app.css" rel="stylesheet">
</head>

<body>
<div class="wrapper">

    <%@include file="../icn/sidebar.jsp" %>
    <div class="main">

        <%@include file="../icn/head.jsp" %>
        <main class="content">
            <div class="container-fluid p-0">
                <h1 class="h3 mb-3" style="margin-left: 100px;font-weight: bold">事项审核</h1>
                <div class="row" style="margin-left: 100px">
                    <div class="col-12 col-xl-10">
                        <div class="card">
                            <div class="card-body">
                                <form action="${pageContext.request.contextPath}/system/declare/declareEdit/${updateList.id}"
                                      method="post">
                                    <div class="form-row ">
                                        <div class="form-group col-md-6">
                                            <label>申报事项</label>
                                           <%-- <input type="text" class="form-control"
                                                   value="${updateList.item.name}"
                                                   placeholder="申报事项" name="item.id">--%>

                                            <input type="text" disabled value="${updateList.item.name}" style="width:100%;padding: 5px 10px">
<%--                                            <select style="width: 150px" name="item.id">--%>
<%--                                                <c:forEach items="${deptLists}" var="add">--%>
<%--                                                <option value="${updateList.item.name}">${updateList.item.name}</option>--%>
<%--                                                    <option value="${add.id}">${add.name}</option>--%>
<%--                                                </c:forEach>--%>
<%--                                            </select>--%>
                                        </div>
<%--                                        <div class="form-group col-md-6">--%>
<%--                                            <label>申报人编号</label>--%>
<%--                                            <input type="text" class="form-control"--%>
<%--                                                   value="${updateList.}"--%>
<%--                                                   placeholder="申报人编号" name="userId" disabled>--%>
<%--                                        </div>--%>
<%--                                        <div class="form-group col-md-6">--%>
<%--                                            <label>负责人编号</label>--%>
<%--                                            <input type="text" class="form-control"--%>
<%--                                                   value="${updateList.itemUserid}"--%>
<%--                                                   placeholder="负责人编号" name="itemUserid">--%>
<%--                                        </div>--%>
                                       <%-- <div class="form-group col-md-6">
                                            <label>申报材料</label>
                                            <input type="text" class="form-control"
                                                   value="${updateList.materialContext}"
                                                   placeholder="审批项目" name="materialId">
                                        </div>--%>
                                        <div class="form-group col-md-6">
                                            <label>申报时间</label>
                                            <div class="form-group">
                                                <div class="input-group" style="border: 1px solid #b3b3b3;padding: 5px 10px">
                                                    <fmt:formatDate value="${updateList.createTime}" pattern="yyyy-MM-dd"/>
<%--                                                    <input type="date" class="form-control wk-normal-input" id="mark"--%>
<%--                                                           value="${updateList.createTime}" placeholder="办理时间"--%>
<%--                                                           name="createTime" disabled>--%>

                                                </div>
                                            </div>
                                        </div>
<%--                                        <div class="form-group col-md-6">--%>
<%--                                            <label>审批时间</label>--%>
<%--                                            <div class="form-group">--%>
<%--                                                <div class="input-group">--%>
<%--                                                    <fmt:formatDate value="${updateList.processingTime}" pattern="yyyy-MM-dd"/>--%>
<%--                                                    <input type="date" class="form-control wk-normal-input" id="mark"--%>
<%--                                                           value="${updateList.processingTime}" placeholder="办理时间"--%>
<%--                                                           name="processingTime">--%>

<%--                                                </div>--%>
<%--                                            </div>--%>
<%--                                        </div>--%>
                                        <div class="form-group col-md-6">
                                            <label>办理状态</label>

                                            <select name="status" id="" style="width:100%;padding: 5px 10px">
                                                <option value="${updateList.status}" style="color: red">
                                                    现在状态：${updateList.status == 1?"未通过":updateList.status == 3?"通过":"待审核"}
                                                </option>
                                                <option value="1">未通过</option>
                                                <option value="3">通过</option>
                                            </select>
<%--                                            <input type="number" min="1" max="3" class="form-control"--%>
<%--                                                   value="${updateList.status}"--%>
<%--                                                   placeholder="“1”：未通过、“2”：等待审批、“3”：通过" name="status">--%>

                                        </div>
                                        <div class="form-group col-md-6">
                                            <label>备注</label>
                                            <input type="text" class="form-control"
                                                   value="${updateList.remark}"
                                                   placeholder="备注" name="remark" disabled>
                                        </div>


                                        <a href="" class="yw-sfwxze" style="" onclick="f()">审批材料下载</a>


                                    </div>

                                    <div style="text-align: center">
                                        <button type="submit" class="btn btn-primary">提交</button>
                                        <button type="text" class="btn btn-secondary"><a
                                                href="${pageContext.request.contextPath}/system/declare/declareList"
                                                style="color: white;text-decoration: none">返回</a></button>
                                    </div>
                                </form>
                            </div>
                        </div>
                    </div>
                </div>
            </div>
        </main>

    </div>
</div>

<%--<script src="${pageContext.request.contextPath}/js/vendor.js"></script>--%>
<script src="${pageContext.request.contextPath}/js/app.js"></script>

<script>
    function f() {
        <%--// alert(l)--%>
        <%--console.log(123);--%>
        <%--alert("${updateList.materialFilePath}")--%>
        let url="${updateList.materialFilePath}"
        <%--window.open("${updateList.materialFilePath}","_blank")--%>

        let link = document.createElement("a");
        link.style.display = "none";
        link.href = url;
        link.download = "审批材料";
        document.body.appendChild(link);
        link.click();
        window.URL.revokeObjectURL(link.href);

    }
</script>
</body>

</html>